#!/usr/bin/env python
# -*- coding:utf-8 -*-
# @Time: 2022/12/22 11:25
# @Author: scg
# @Email: xxx@gmail.com
# @File：driver.py

from selenium import webdriver
from config.config import  HOST
from tools import  globalvar as gl


def chrome():
    driver = webdriver.Chrome()
    driver.maximize_window()

    driver.get("http://{}".format(HOST))
    driver.add_cookie(gl.get_value("cookie"))
    return driver
